/*
 * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
 * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
 */
package oop.demo.restaurantmanagementsystem;

/**
 * Ingredient class for managing individual ingredients
 * name: The name of the ingredient
 * price: The price of the ingredient
 * @author ashongtical
 */
public class Ingredient implements Priceable {
    private String name;
    private double price;
    
    public Ingredient(String name,double price){
        this.name = name;
        this.price = price;
    }
    
    public String getName(){
        return this.name;
    }
    
    @Override
    public double getPrice(){
        return this.price;
    }
    
    public String toString(){
        return name + ":" + price + "RMB";
    }
    
}
